package com.sc.nft.enums.ecologypool;

import com.baomidou.mybatisplus.annotation.EnumValue;
import com.google.common.collect.Maps;
import lombok.AllArgsConstructor;
import lombok.Getter;

import java.util.Map;

@Getter
@AllArgsConstructor
public enum EcologyPoolRedPackEnum {

    ECOLOGY_POOL_OPEN_RED_PACK(17, "开启红包", false),
    OPEN_READ_PACK_RECEIVE(18, "open_read_pack_receive_", false),
    ;


    @EnumValue
    private final int code;

    private final String desc;

    /**
     * 用来判定任务是否需要有额外的选项配置.比如需要选择指定的ip商城商品or自由市场藏品
     */
    private final Boolean configuration;

    public static Map<String, String> getAll() {
        Map<String, String> map = Maps.newLinkedHashMap();
        for (EcologyPoolRedPackEnum value : EcologyPoolRedPackEnum.values()) {
            map.put(value.name(), value.getDesc());
        }
        return map;
    }
}
